]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
gdm, util: Always allow to retry login in unlock mode
authorMarco Trevisan (Treviño) <mail@3v1n0.net>
Tue, 29 May 2018 00:10:09 +0000 (03:10 +0300)
committerMarco Trevisan <mail@3v1n0.net>
Wed, 25 Jul 2018 20:32:42 +0000 (20:32 +0000)
When in lockscreen mode there's no point of resetting the auth login as there's
no welcome screen, and that would just cause the UI to freeze, with no reason.
This could have been useful if we were stopping the user to login for a given
time after ALLOWED_FAILURES attempts, but this is not the case yet.

js/gdm/util.js

index 1c6150edad0ec45eecccba9b73d2e5ecfd7ea570..eac8ccd508be01ca36ada51e86df8b249b377f3d 100644 (file)
@@ -537,12 +537,13 @@ var ShellUserVerifier = new Lang.Class({
     _verificationFailed(retry) {
         // For Not Listed / enterprise logins, immediately reset
         // the dialog
-        // Otherwise, we allow ALLOWED_FAILURES attempts. After that, we
-        // go back to the welcome screen.
+        // Otherwise, when in login mode we allow ALLOWED_FAILURES attempts.
+        // After that, we go back to the welcome screen.
 
         this._failCounter++;
         let canRetry = retry && this._userName &&
-            this._failCounter < this._settings.get_int(ALLOWED_FAILURES_KEY);
+            (this._reauthOnly ||
+             this._failCounter < this._settings.get_int(ALLOWED_FAILURES_KEY));
 
         if (canRetry) {
             if (!this.hasPendingMessages) {